<template>
	<view class="content">
		<view class="header">
			<view class="left">
				奢品微信：37598
			</view>
			<view @click="copy" class="right">
				<u-icon style="margin-right: 5px; margin-top:2px;" name="weixin-fill" size="36"></u-icon>
				点击复制
			</view>
		</view>
		<img src="../static/img/1.jpg" alt="" srcset="">
		<img src="../static/img/2.jpg" alt="" srcset="">
		<view @click="copy" class="wz">
			<view class="tit">
				微信号:37598
			</view>
			<view class="detail">

				长按复制微信号，去微信搜索添加

			</view>
		</view>
		<img src="../static/img/3.jpg" alt="" srcset="">
		<img src="../static/img/4.jpg" alt="" srcset="">
		<img src="../static/img/5.jpg" alt="" srcset="">
		<img src="../static/img/6.jpg" alt="" srcset="">
		<img src="../static/img/7.jpg" alt="" srcset="">
		<img src="../static/img/8.jpg" alt="" srcset="">
		<img src="../static/img/9.jpg" alt="" srcset="">
		<img src="../static/img/10.jpg" alt="" srcset="">

		<view class="desc">
			<view class="line">
				芦淞区新潮鞋帽百货店
			</view>
			<view class="line">

				<img class="icon" src="../static/img/11.png" alt="">
				登录享网民权益保障，如遇欺诈等可
				<text>申请保障</text>
			</view>
			<view class="ul">
				<view class="li">
					<img class="icon1" src="../static/img/12.png" alt="">协助维权
				</view>
				<view class="li">
					<img class="icon1" src="../static/img/12.png" alt="">虚假赔偿
				</view>
				<view class="li">
					<img class="icon1" src="../static/img/12.png" alt="">欺诈赔偿
				</view>
			</view>
		</view>

		<view class="footer">
			<view class="left">
				37598：加微即享优惠
			</view>
			<view @click="copy" class="right">
				<u-icon style="margin-right: 5px; margin-top:2px;" name="weixin-fill" size="36"></u-icon>
				点击复制
			</view>
		</view>

		<u-popup :closeable="true" width="80%" v-model="show" border-radius="10" mode="center">
			<view class="info">
				<view class="title">
					添加微信好友，详细了解更多款式及价格
				</view>
				<view class="main">
					微信号:37598
				</view>
				<u-button @click="copy1" type="success">复制微信号</u-button>
			</view>
		</u-popup>

		<u-popup :closeable="true" width="80%" v-model="show1" border-radius="10" mode="center">
			<view class="info">
				<image class="logo" src="../static/img/13.png" mode=""></image>
				<view class="title" style="margin-bottom: 10px;">
					复制成功
				</view>
				<view class="same">
					微信号:37598
				</view>
				<view class="same">

					添加微信好友，详细了解更多款式及价格

				</view>
				<u-button @click="ok" type="success">知道了</u-button>
			</view>
		</u-popup>
	</view>
</template>

<script>
	import Clipboard from 'clipboard';
	export default {
		data() {
			return {
				show: false,
				show1: false
			}
		},
		methods: {
			ok(){
				this.show1 = false
				this.show = false
			},
			copy(){
				this.show = true
			},
			copy1() {
				this.$copyText('37598').then(
					res => {
						console.log('复制成功')
						this.show = false
						this.show1 = true
					},
					err => {
						console.log('复制失败')
					}
				);
			},
		}
	}
</script>

<style scoped lang="scss">
	.logo {
		display: block;
		width: 30px;
		height: 30px;
		margin: 0 auto 5px;
	}

	.same {
		color: #666;
		text-align: center;
		margin-bottom: 10px;
	}

	.info {
		padding: 30px 20px;

		.title {
			color: #000;
			text-align: center;
			padding: 0 18px;
			font-weight: bold;
			font-size: 17px;
		}

		.main {
			background: #f7f7f7;
			padding: 20px;
			margin: 20px 0;
			text-align: center;
		}
	}

	.wz {
		padding: 20px 0 0;
		background: rgb(0, 0, 0);

		.tit {
			color: rgb(26, 173, 23);
			text-align: center;
			font-size: 18px;
			font-weight: bold;

		}

		.detail {
			text-align: center;
			color: #fff;
			padding: 10px 0 20px 0;
		}
	}

	.icon {
		width: 18px;
		height: 18px;
	}

	.icon1 {
		width: 12px;
		height: 12px;
		margin-right: 5px;

	}

	.content {
		padding-bottom: 60px;

		.desc {
			background: #1b1b1b;
			font-size: 12px;
			color: rgba(255, 255, 255, 0.5);
			padding: 20px 15px;

			.line {
				margin-bottom: 10px;
				display: flex;
				align-items: center;
				justify-content: center;
			}

			.ul {
				display: flex;
				align-items: center;

				.li {
					flex: 1;
					display: flex;
					align-items: center;
				}
			}
		}
	}

	.left {
		height: 60px;
		flex: 2;
		padding-left: 20px;
		color: #fff;
		display: flex;
		align-items: center;
	}

	.right {
		color: #fff;
		display: flex;
		align-items: center;
		justify-content: center;
		height: 60px;
		flex: 1;
		background: #1aad17;
		font-size: 15px;
	}

	.header {
		position: fixed;
		width: 100%;
		top: 0;
		left: 0;
		right: 0;
		display: flex;
		align-items: center;
		justify-content: space-between;
		background: rgb(0, 0, 0);
		height: 60px;


	}

	.footer {
		position: fixed;
		width: 100%;
		bottom: 0;
		left: 0;
		right: 0;
		display: flex;
		align-items: center;
		justify-content: space-between;
		background: rgb(0, 0, 0);
		height: 60px;
	}

	img {
		width: 100%;
		display: block;
		overflow: hidden;
	}
</style>
